{extend name="common/base" /} {block name="body"}
<div id="app">
    <div class="layui-layout layui-layout-admin">
        <div class="layui-header">
            <ul class="layui-nav layui-layout-left">
                <li class="layui-nav-item pc-menu"><a admin-event="changeMenu" class="javascript:;"><i
                        class="layui-icon layui-icon-shrink-right"></i></a></li>
                <li class="layui-nav-item mobile-menu"><a admin-event="changeMobileMenu" class="javascript:;"><i
                        class="layui-icon layui-icon-spread-left"></i></a></li>
                <li class="layui-nav-item pc-show"><a admin-event="getSecondMenu" lay-menuid="0" class="javascript:;">首页</a></li>
                {volist name="topMenu" id="vo" offset="" length='4'}
                <li class="layui-nav-item pc-show"><a admin-event="getSecondMenu" lay-menuid="{$vo.id}" class="javascript:;">{$vo.name}</a></li>
                {/volist} {if count($topMenu)>4}
                <li class="layui-nav-item">
                    <a href="javascript:;"><i class="layui-icon layui-icon-app"></i></a>
                    <dl class="layui-nav-child">
                        {volist name="topMenu" id="vo" offset="5"}
                        <dd><a admin-event="getSecondMenu" lay-menuid="{$vo.id}" href="javascript:;">{$vo.name}</a></dd>
                        {/volist}
                    </dl>
                </li>
                {/if}
                <li class="layui-nav-item mobile-menu">
                    <a href="javascript:;">模块</a>
                    <dl class="layui-nav-child">
                        <dd><a admin-event="getSecondMenu" lay-menuid="0" href="javascript:;">快捷菜单</a></dd>
                        {volist name="topMenu" id="vo"}
                        <dd><a admin-event="getSecondMenu" lay-menuid="{$vo.id}" href="javascript:;">{$vo.name}</a></dd>
                        {/volist}
                    </dl>
                </li>
            </ul>
            <ul class="layui-nav layui-layout-right">
                <li class="layui-nav-item" lay-unselect>
                    <a href="javascript:;" data-href="http://uinge.com" lay-text="消息中心">
                        <i class="layui-icon layui-icon-notice"></i>
                    </a>
                </li>
                <li class="layui-nav-item" lay-unselect>
                    <a href="javascript:;" admin-event="refresh">
                        <i class="layui-icon layui-icon-refresh"></i>
                    </a>
                </li>
                <li class="layui-nav-item" lay-unselect>
                    <a href="javascript:;">
                        {:$uinfo.user_nickname?:$uinfo.user_login}
                    </a>
                    <dl class="layui-nav-child">
                        <dd lay-unselect><a href="javascript:;" data-href="{:url('/admin/profile')}" lay-text="个人资料">个人资料</a></dd>
                        <dd lay-unselect><a href="javascript:;" data-href="{:url('/admin/profile/changePwd')}" lay-text="修改密码">修改密码</a></dd>
                        <dd lay-unselect><a href="javascript:;" style="{:html_cmf_auth_check('admin/View.options/clearCache')}" data-ajax-href="{:url('admin/options/clearCache')}" lay-text="清除缓存">清除缓存</a></dd>
                        <dd lay-unselect><a href="{:url('/admin/logout')}">退出登录</a></dd>
                    </dl>
                </li>
            </ul>
        </div>
        <div class="layui-side layui-side-menu layui-bg-black">
            <div class="layui-side-scroll">
                <div class="layui-logo">
                    <span class="big-logo">Inge Php</span>
                    <span class="small-logo">Inge</span>
                </div>
                <ul class="layui-nav layui-nav-tree">

                </ul>
            </div>
        </div>
        <div class="admin-tabs">
            <div class="layui-prev-controller layui-icon layui-icon-prev"></div>
            <div class="layui-tab" lay-unauto lay-allowClose="true" lay-filter="layui-admin-tabs">
                <ul class="layui-tab-title">
                    <li lay-id='/admin/dashboard.html' class="layui-this">首页</li>
                </ul>
            </div>
            <div class="layui-next-controller layui-icon layui-icon-next"></div>
            <div class="layui-down-controller layui-icon layui-icon-down">
                <ul class="layui-nav layui-more-controller" lay-filter="admin-tabs-close-nav">
                    <li class="layui-nav-item" lay-unselect>
                        <a href="javascript:;"></a>
                        <dl class="layui-nav-child layui-unselect">
                            <dd lay-unselect><a class="closeNowTab" href="javascript:;">关闭当前标签页</a></dd>
                            <dd lay-unselect><a class="closeOtherTab" href="javascript:;">关闭其他标签页</a></dd>
                            <dd lay-unselect><a class="closeRightTab" href="javascript:;">关闭右侧标签页</a></dd>
                            <dd lay-unselect><a class="closeLeftTab" href="javascript:;">关闭左侧标签页</a></dd>
                            <dd lay-unselect><a class="closeAllTab" href="javascript:;">关闭所有标签页</a></dd>
                        </dl>
                    </li>
                </ul>
            </div>
        </div>
        <div class="layui-body">
            <!-- 内容主体区域 -->
            <div class="admin-tabs-body layui-show">
                <iframe class="admin-tabs-body-iframe" src="/admin/dashboard.html"></iframe>
            </div>
        </div>
        <div class="admin-body-shade" admin-event="shade"></div>
    </div>
</div>
{/block} {block name="my_js"}
<script>
    layui.use(['element', 'admin'], function() {
        var element = layui.element,
            admin = layui.admin;
        admin.changeAdminTab(element);
        layui.event("getSecondMenu", "getSecondMenu('')", {
            'id': 0
        });
        admin.prevAdminTab();
        admin.nextAdminTab();
        admin.bindCloseTab();
    });
</script>
{/block}